import request from '@/utils/request'

//点检项
export function getPathItemAPI(data) {
    return request({
        url: '/item/searchItemByPage.ashx',
        method: 'post',
        data
    })
}

//新增点检项 
export function createPathItemAPI(data) {
    return request({
        url: '/item/addItem.ashx',
        method: 'post',
        data,
    })
}

// 编辑点检项 
export function editPathItemAPI(data) {
    return request({
        url: '/item/modifyItem.ashx',
        method: 'post',
        data,
    })
}

//删除点检项 
export function deletePathItemAPI(data) {
    return request({
        url: '/item/deleteItem.ashx',
        method: 'post',
        data
    })
}

//路径
export function getPathLineAPI(data) {
    return request({
        url: '/path/searchPathByPage.ashx',
        method: 'post',
        data
    })
}

//新增路径
export function createPathLineAPI(data) {
    return request({
        url: '/path/addPath.ashx',
        method: 'post',
        data,
    })
}

// 编辑路径
export function editPathLineAPI(data) {
    return request({
        url: '/path/modifyPath.ashx',
        method: 'post',
        data,
    })
}

//删除路径
export function deletePathLineAPI(data) {
    return request({
        url: '/path/delPath.ashx',
        method: 'post',
        data,
    })
}

// 获取该路径下的所有点检项
export function getPathItemByPathAPI(data) {
    return request({
        url: '/pathitem/getPathItemByPathid.ashx',
        method: 'post',
        data
    })
}

// 删除路径下的指定点检项
export function deletePathItemByPathAPI(data) {
    return request({
        url: '/pathitem/delPathItemByPiid.ashx',
        method: 'post',
        data
    })
}

// 添加路径下的指定点检项
export function addPathItemByPathAPI(data) {
    return request({
        url: '/pathitem/addPathItem.ashx',
        method: 'post',
        data,
    })
}

// 查询路径执行计划
export function getScheByCondPageAPI(data) {
    return request({
        url: '/sche/getScheByCondPage.ashx',
        method: 'post',
        data,
    })
}

// 新建路径执行计划
export function addScheAPI(data) {
    return request({
        url: '/sche/addSche.ashx',
        method: 'post',
        data,
    })
}

// 编辑路径执行计划
export function editScheAPI(data) {
    return request({
        url: '/sche/updateSche.ashx',
        method: 'post',
        data,
    })
}

// 删除路径执行计划
export function deleteScheAPI(data) {
    return request({
        url: '/sche/delSche.ashx',
        method: 'post',
        data,
    })
}

